package com.jredu.controller.server;

import java.util.HashMap;
import java.util.Map;

import org.springframework.http.converter.StringHttpMessageConverter;
import org.springframework.stereotype.Controller;
import org.springframework.ui.Model;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.servlet.ModelAndView;

@Controller
@RequestMapping("/dept")
public class DeptController {

	@RequestMapping("/findDepts")
	public ModelAndView findDepts(){
		
		ModelAndView mav = new ModelAndView();
		mav.addObject("dept", "移动开发部");
		mav.setViewName("depts/index");
		return mav;
	}
	
	@RequestMapping("/findDeptById")
	public String findDeptById(Map<String, Object> map){
		map.put("dept", "杰瑞教育");
		//return "depts/index";
		return "forward:findDepts";
	}
}
